# @summary A short summary of the purpose of this class
#
# A description of what this class does
#
# @example
#   include clusters::autofs
class clusters::autofs {
  include autofs
  autofs::mount { 'ihep':
    mount   => '/-',
    mapfile => '/etc/auto.ihep',
    options => '--timeout=120',
    use_dir => true,
  }
  autofs::mount { 'local':
    mount   => '/ihepbatch',
    mapfile => '/etc/auto.local',
    options => '--timeout=120',
    use_dir => true,
  }

  autofs::mapfile { 'ihep':
    path     => '/etc/auto.ihep',
    mappings => [
      { 'key' => '/home/lhaaso', 'options' => 'fstype=nfs,soft,soft,intr,retrans=20,timeo=15,nfsvers=3,nosuid', 'fs' => 'lhuser.ihep.ac.cn:/lhaasohome' },
    ]
  }
  autofs::mapfile { 'local':
    path     => '/etc/auto.local',
    mappings => [
      { 'key' => 'bsrf', 'options' => '-fstype=nfs,soft,rsize=32768,wsize=32768,soft,intr,retrans=20,timeo=15,nfsvers=4,nosuid', 'fs' => '192.168.51.143:/home/bsrf' },
      { 'key' => 'lhc', 'options' => '-fstype=nfs,soft,rsize=32768,wsize=32768,soft,intr,retrans=20,timeo=15,nfsvers=4,nosuid', 'fs' => '192.168.51.143:/home/lhc' },
      { 'key' => 'cc', 'options' => '-fstype=nfs,soft,rsize=32768,wsize=32768,soft,intr,retrans=20,timeo=15,nfsvers=4,nosuid', 'fs' => '192.168.51.143:/home/cc' },
    ]
  }
}
